<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="renderer" content="webkit|ie-comp|ie-stand">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport"
          content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no"/>
    <meta http-equiv="Cache-Control" content="no-siteapp"/>
    <title>审核</title>
    <link rel="stylesheet" type="text/css" href="../../../static/h-ui/css/H-ui.min.css"/>
    <link rel="stylesheet" type="text/css" href="../../../static/h-ui.admin/css/H-ui.admin.css"/>
    <link rel="stylesheet" type="text/css" href="../../../lib/Hui-iconfont/1.0.8/iconfont.css"/>
    <link rel="stylesheet" type="text/css" href="../../../static/h-ui.admin/skin/default/skin.css" id="skin"/>
    <link rel="stylesheet" type="text/css" href="../../../ht-css/Project.css"/>
    <link rel="stylesheet" type="text/css" href="../../../static/h-ui.admin/css/style.css"/>
    <link rel="stylesheet" href="../../../ht-css/serviceProvider/examination.css">
    <link rel="stylesheet" href="../../../ht-css/serviceProvider/pendingExamination.css">
    <link href="../../../ht-css/serviceProvider/customerProperProduct/customerUpdate.css" rel="stylesheet" />
    
</head>
<body>
<!--模块一-->
<div class="section1">
    <div class="title">审核单信息</div>
    <table class="table_li ml-10 mb-10 table">
        <tr>
            <td class="col-2-1 ">
                <label class="form-label f-l pt-5">服务商名称：</label>
                <span class="f-l pt-5 providerName"></span>
            </td>
            <td class="col-2-1 ">
                <!--customerName -- belongChannel-->
                <label class="form-label f-l pt-5">专属渠道：</label>
                <span class="f-l pt-5 belongChannel"></span>
            </td>
        </tr>
        <tr>
            <td class="col-2-1 ">
                <label class="form-label f-l pt-5">状态：</label>
                <span class="f-l pt-5 auditStatus"></span>
            </td>
            <td class="col-2-1 ">
                <label class="form-label f-l pt-5">更新时间：</label>
                <span class="f-l pt-5 updateTime"></span>
            </td>
        </tr>
    </table>
</div>
<!--模块二-->
<div class="section1">
    <div class="title">基本信息</div>
    <table class=" table_li ml-10 mb-10 table">
        <tr>
            <td class="col-2-1 ">
                <label class="form-label f-l pt-5">商品名称：</label>
                <div class="formControls f-l input-brandName" style="display: none">
                    <input style="width: 176px;" type="text" maxlength="40" class="input-text radius ml-10 inputSpuName" placeholder="请输入商品名称">
                </div>
                <span class="f-l pt-5 spuName"></span>
            </td>
            <td class="col-2-1 ">
                <label class="form-label f-l pt-5">商品分类：</label>
                <span class="f-l pt-5 defaultClassify"></span>
                <div style="display: none" id="thirdClassify">
                    <span class="select-box size-M radius col-xs-8 ml-10" style="width:15%">
                         <select class="select" name="first" id="first">
                            <option value="" selected>请选择一级品类</option>
                        </select>
                     </span>
                    <span class="select-box size-M radius col-xs-8 ml-10" style="width:15%">
                        <select class="select" name="second" id="second">
                            <option value="" selected>请选择二级品类</option>
                        </select>
                     </span>
                    <span class="select-box size-M radius col-xs-8 ml-10" style="width:15%">
                        <select class="select" name="third" id="third">
                            <option value="" selected>请选择三级品类</option>
                        </select>
                     </span>
                     <span class="select-box size-M radius col-xs-8 ml-10" style="width:15%">
                        <select class="select" name="fourth" id="fourth">
                            <option value="" selected>请选择四级分类</option>
                        </select>
                     </span>
                </div>
                <span style="color: #0a60d6;cursor: pointer;line-height: 26px">
                    <span id="modify">修改</span>
                </span>
                <span style="color: #0a60d6;cursor: pointer;line-height: 26px">
                    <span style="margin-left:18px;display: none" id="cancel-modify">取消</span>
                </span>
            </td>
        </tr>
        <tr>
            <td class="col-2-1 ">
                <label class="form-label f-l pt-5">归类名称：</label>
                <span class="f-l pt-5 classificationName"></span>
                <span class="select-box size-M radius col-xs-8 ml-10" style="width:176px;display: none" id="classifyName">
                         <select class="select" id="nameClassify">
                            <option value="" selected>请选择归类名称</option>
                        </select>
                     </span>
            </td>
            <td class="col-2-1 ">
                <label class="form-label f-l pt-5">税类编码：</label>
                <span class="f-l pt-5 revenueCode"></span>
            </td>
        </tr>
        <tr>
            <td class="col-2-1 ">
                <label class="form-label f-l pt-5">品牌：</label>
                <div class="formControls f-l select-brand" style="display: none">
                    <div class="formControls f-l input-brand"  style="display: none">
                        <input style="width: 176px;" type="text"  autocomplete="off" class="input-text radius ml-10" placeholder="请输入自定义品牌" id="brand-input">
                    </div>

                    <div class="formControls f-l select-brand-input" >
                        <input type="text" autocomplete="off" class="input-text radius ml-10 f-l w-180 h-26 " name="brand" placeholder="请选择品牌" id="brand-select">
                        <ul class="w-180 ml-10 mt-30 radius  relation select-list-box brand-lists" style="display: none">
                        </ul>
                    </div>
                    <span class="f-l pt-5 pl-5 add-brand-warp">没有找到想要的品牌
                        <span style="color: #0a60d6;cursor: pointer" class="add-brand">点击此处添加</span>
                    </span>
                    <span style="color: #0a60d6;cursor: pointer; margin-left:5px;display: none" class="exist-brand">选择已有商品</span>
                </div>
                <span class="f-l pt-5 brandName"></span>
            </td>
           <!-- <td class="col-2-1 ">
                <label class="form-label f-l pt-5">限制类型：</label>
                <span class="f-l pt-5 restricted">非限制类</span>
            </td>-->
        </tr>
        <tr>
          <!--  <td class="col-2-1 ">
                <label class="form-label f-l pt-5">材质：</label>
                <span class="f-l pt-5 material">我是材质</span>
            </td>-->
            <td class="col-2-1 ">
                <label class="form-label f-l pt-5">限制类型：</label>
                <span class="f-l pt-5 restricted"></span>
            </td>
        </tr>
    </table>
    <div style="margin-left: 10px">
        <ul class="warp picture">
            <li class="left">图片：</li>

        </ul>
        <!-- <ul class="warp">
            <li class="left">商品资质：</li>
            <li class="right product_qualification" >
                <img src="../../../img/Pdf.png" alt="" class="goodsQualification">
                <a href="" id="downLoadQualification">点击下载附件查看</a>
            </li>
        </ul> -->
        <div class="mt-15 pb-30 imgTable clearfix">
            <div style="display: inline-block;margin-right:5px">商品资质：</div>
            <!-- <div style="display: inline-block">
                <img  class="f-l ml-10"  id="qualification-img" src="../../../img/Pdf.png" style="margin-right: 10px;display: none" >
                <div style="width: 200px">
                    <a href="" id="downLoadQualification" style="display: none">点击下载附件查看</a>
                    <div id="cancelFile" style="cursor: pointer;margin-top: 12px; color: #1476e5;display: none">删除</div>
                </div>
                <img  class="f-l ml-10" style="width: 50px;height: 50px;" id="pdfOperate" src="../../../img/tianjia.png">
                <input id="filePdf" type="file" accept=".pdf"  style="display: none">
            </div> -->
    
            <!--改造-->
            <div id="qualification_list">
            </div>
            
            <!--改造-->
        </div>
        <div style="margin-left: 8px;padding-bottom: 10px;margin-top: 10px">
            <span>销售区域：</span>
            <ul style="display: inline-block" class="saleAreaWarp">
            </ul>
        </div>
    </div>
</div>
<form id="tableForm" method="post">
    <!--模块三 单个商品-->
    <div class="section1 singleTable" style="display: none">
        <div class="title">规格信息</div>
        <table class="table table-border table-bg table-hover table-sort mt-10" id="datatable1">
            <thead>
            <tr class="text-c">
                <th width="150px">规格</th>
                <th width="150px">颜色</th>
                <th width="150px">售价</th>
                <th width="50px"></th>
                <th width="150px">鑫方盛采购价</th>
                <th width="150px">预计出货日</th>
                <th width="150px">最小起订量</th>
                <th width="200px">最长边</th>
                <th width="200px">体积</th>
                <th width="200px">重量</th>
            </tr>
            </thead>
            <tbody class="singleBody">
            </tbody>
        </table>
    </div>
    <!-- 模块三 多个商品-->
    <div class="section1 multipleTable" style="display: none">
        <div class="title">规格信息</div>
        <table class="table table-border table-bg table-hover table-sort mt-10" id="datatable2">
            <thead>
            <tr class="text-c">
                <th width="150px"><input type="checkbox" id="selectAll"> &nbsp;&nbsp;&nbsp;&nbsp;规格</th>
                <th width="150px">颜色</th>                
                <th width="150px">售价</th>
                <th width="50px"></th>
                <th width="150px">鑫方盛采购价</th>
                <th width="150px">预计出货日</th>
                <th width="150px">最小起订量</th>
                <th>最长边</th>
                <th>体积</th>
                <th>重量</th>
            </tr>
            </thead>
            <tbody class="tbody multipleBody">
            </tbody>
        </table>
    </div>
</form>

<!-- 模块四-->
<div class="section1">
    <div class="title">详细信息</div>
    <div class="detail" style="padding: 10px"></div>
    <div class="edit-detail" style="display: none">
        <div class="pd-20">
            <script id="editor" type="text/plain" style="width: 100%; height: 500px"></script>
        </div>
        <input id="forJsFileBtn" type="file" accept=".jpg,.jpeg,.png" onchange="uploadPicture(event)" style="display: none"/>
    </div>
</div>
<div class="button">
    <div class="buttonLeft-name">审核通过</div>
    <div class="buttonRight-name">审核驳回</div>
</div>
<!-- 审核不通过弹窗-->
<div class="model">
    <div class="content">
        <div class="title">
            <div class="title-left">审核驳回</div>
            <!--<div class="title-right">X</div>-->
        </div>
        <textarea class="textarea" name="reason" id="reason" cols="30" rows="10"  onKeyUp="value=value.replace(/\s+/g,'')" placeholder="请输入审核驳回原因，以便服务商按照要求进行修改" maxlength="200"></textarea>
        <div class="reason-btn">
            <label class="reason-label" for="reason-1">图片模糊</label><input type="checkbox" name="reason_name" id="reason-1" value="图片模糊" class="reason-cb">
            <label class="reason-label" for="reason-2">图片不能出现除品牌以外的水印</label><input type="checkbox" name="reason_name" id="reason-2" value="图片不能出现除品牌以外的水印" class="reason-cb">
            <label class="reason-label" for="reason-3">商品品牌与图片品牌不一致</label><input type="checkbox" name="reason_name" id="reason-3" value="商品品牌与图片品牌不一致" class="reason-cb">
            <label class="reason-label" for="reason-4">商品是我司正常商品,无法重复上架</label><input type="checkbox" name="reason_name" id="reason-4" value="商品是我司正常商品,无法重复上架" class="reason-cb">
            <label class="reason-label" for="reason-5">商品修改价格不得超过20%</label><input type="checkbox" name="reason_name" id="reason-5" value="商品修改价格不得超过20%" class="reason-cb">
            <label class="reason-label" for="reason-6">已有审核通过商品,请勿重复提交</label><input type="checkbox" name="reason_name" id="reason-6" value="已有审核通过商品,请勿重复提交" class="reason-cb">
        </div>
        <div class="modelBtn">
            <button type="button" class="cancel-btn">取消</button>
            <button type="button" class="sure-btn">确定</button>
        </div>
    </div>
</div>
<!--_footer 作为公共模版分离出去-->
<script type="text/javascript" src="../../../lib/jquery/1.9.1/jquery.min.js?rev=@@hash"></script>
<script type="text/javascript" src="../../../lib/layer/2.4/layer.js?rev=@@hash"></script>
<script type="text/javascript" src="../../../static/h-ui/js/H-ui.min.js?rev=@@hash"></script>
<script type="text/javascript" src="../../../static/h-ui.admin/js/H-ui.admin.js?rev=@@hash"></script>
<!--/_footer 作为公共模版分离出去-->
<!--时间脚本-->
<script type="text/javascript" src="../../../lib/jedate-6.5.0/dist/jedate.min.js?rev=@@hash"></script>
<!--表单验证-->
<script type="text/javascript" src="../../../lib/jquery.validation/1.14.0/jquery.validate.js?rev=@@hash"></script>
<script type="text/javascript" src="../../../lib/jquery.validation/1.14.0/validate-methods.js?rev=@@hash"></script>
<script type="text/javascript" src="../../../lib/jquery.validation/1.14.0/messages_zh.js?rev=@@hash"></script>
<script type="text/javascript" src="../../../lib/Validform/5.3.2/Validform_v5.3.2_min.js?rev=@@hash"></script>
<script type="text/javascript" src="../../../lib/datatables/1.10.0/jquery.dataTables.min.js?rev=@@hash"></script>
<script type="text/javascript" src="../../../lib/laypage/1.2/laypage.js?rev=@@hash"></script>
<script src="../../../ht-js/public.js?rev=@@hash"></script>
<!--验证token-->
<script src="../../../ht-js/verifyToken.js?rev=@@hash"></script>
<script src="../../../lib/pagination/jquery.pagination.js?rev=@@hash"></script>
<script type="text/javascript" src="../../../ht-js/frame/doT.min.js?rev=@@hash"></script>
<!--富文本编辑器-->
<script type="text/javascript" charset="utf-8" src="../../../lib/ueditor/1.4.3/ueditor.config.js?rev=@@hash"></script>
<script type="text/javascript" charset="utf-8" src="../../../lib/ueditor/1.4.3/ueditor.all.min.js?rev=@@hash"> </script>
<!--建议手动加在语言，避免在ie下有时因为加载语言失败导致编辑器加载失败-->
<!--这里加载的语言文件会覆盖你在配置项目里添加的语言类型，比如你在配置项目里配置的是英文，这里加载的中文，那最后就是中文-->
<script type="text/javascript" charset="utf-8" src="../../../lib/ueditor/1.4.3/lang/zh-cn/zh-cn.js?rev=@@hash"></script>

<script>
    var skuFormData = new FormData();
    var spuImgCount = 0;
    var ue = UE.getEditor('editor',{
        toolbars: [
            [
                'source', //源代码
                'anchor', //锚点
                'undo', //撤销
                'redo', //重做
                'bold', //加粗
                'indent', //首行缩进
                // 'snapscreen', //截图
                'italic', //斜体
                'underline', //下划线
                'strikethrough', //删除线
                'subscript', //下标
                'fontborder', //字符边框
                'superscript', //上标
                'formatmatch', //格式刷

                'blockquote', //引用
                'pasteplain', //纯文本粘贴模式
                'selectall', //全选
                'print', //打印
                'preview', //预览
                'horizontal', //分隔线
                'removeformat', //清除格式
                'time', //时间
                'date', //日期
                'unlink', //取消链接
                'insertrow', //前插入行
                'insertcol', //前插入列
                'mergeright', //右合并单元格
                'mergedown', //下合并单元格
                'deleterow', //删除行
                'deletecol', //删除列
                'splittorows', //拆分成行
                'splittocols', //拆分成列
                'splittocells', //完全拆分单元格
                'deletecaption', //删除表格标题
                'inserttitle', //插入标题
                'mergecells', //合并多个单元格
                'deletetable', //删除表格
                'cleardoc', //清空文档
                'insertparagraphbeforetable', //”表格前插入行”
                'insertcode', //代码语言
                'fontfamily', //字体
                'fontsize', //字号
                'paragraph', //段落格式
                /*'simpleupload', //单图上传
                'insertimage', //多图上传*/
                'edittable', //表格属性
                'edittd', //单元格属性
                'link', //超链接
                'emotion', //表情
                'spechars', //特殊字符
                'searchreplace', //查询替换
                'map', //Baidu地图
                'gmap', //Google地图
                'insertvideo', //视频
                'help', //帮助
                'justifyleft', //居左对齐
                'justifyright', //居右对齐
                'justifycenter', //居中对齐
                'justifyjustify', //两端对齐
                'forecolor', //字体颜色
                'backcolor', //背景色
                'insertorderedlist', //有序列表
                'insertunorderedlist', //无序列表
                'fullscreen', //全屏
                'directionalityltr', //从左向右输入
                'directionalityrtl', //从右向左输入
                'rowspacingtop', //段前距
                'rowspacingbottom', //段后距
                'pagebreak', //分页
                'insertframe', //插入Iframe
                'imagenone', //默认
                'imageleft', //左浮动
                'imageright', //右浮动
                // 'attachment', //附件
                'imagecenter', //居中
                'wordimage', //图片转存
                'lineheight', //行间距
                'edittip ', //编辑提示
                'customstyle', //自定义标题
                'autotypeset', //自动排版
                'webapp', //百度应用
                'touppercase', //字母大写
                'tolowercase', //字母小写
                'background', //背景
                'template', //模板
                'scrawl', //涂鸦
                'music', //音乐
                'inserttable', //插入表格
                'drafts', // 从草稿箱加载
                // 'charts', // 图表
            ]
        ]
    });
    UE.registerUI('dialog',function(editor,uiName){
            var btn = new UE.ui.Button({
                name:'上传图片',
                title:'上传图片',
                //需要添加的额外样式，指定icon图标，这里默认使用一个重复的icon
                cssRules :'background-position: -726px -77px;',
                onclick:function () {
                    var forJsFileBtn = $("#forJsFileBtn") ;
                    if (forJsFileBtn){
                        forJsFileBtn.click() ;
                    }
                    //渲染dialog
//                    dialog.render();
//                    dialog.open();
                }
            });

            return btn;
        }
        /*index 指定添加到工具栏上的那个位置，默认时追加到最后,editorId 指定这个UI是那个编辑器实例上的，默认是页面上所有的编辑器都会添加这个按钮*/);
    function uploadPicture(e,val) {
        for (var i = 0; i < e.target.files.length; i++) {
            var file = e.target.files.item(i);
            if (!(/^image\/.*$/i.test(file.type))) {
                $.Huimodalalert("请选择图片类型", 2000);
                continue; //不是图片 就跳出这一次循环
            }
            //实例化FileReader API
            var freader = new FileReader();
            freader.readAsDataURL(file);
            freader.onload = function (e) {
                var formData = new FormData();
                formData.set('file', $("#forJsFileBtn")[0].files[0]);
                uploadDetailPicInfo(formData)
            }
        }
    }
    function uploadDetailPicInfo(formData){
        $.ajax({
            url: root.serviceProviderManagement.uploadForIE8,
            cache: false,  //禁用缓存
            type: "POST",
            // 告诉jQuery不要去处理发送的数据
            processData: false,
            // 告诉jQuery不要去设置Content-Type请求头
            contentType: false,
            data: formData,
            success: function (data) {
                var result = JSON.parse(data);
                var fullPath = result[0].fullPath;
                var value = "<img src='" + fullPath + "'>";
                if(value){
                    UE.getEditor('editor').execCommand('insertHtml', value)
                }
            },
        })
    }
</script>
<!--页面js-->
<script src="../../../ht-js/serviceProvider/pendingApprovalProduct/pendingExamination.js"></script>
</body>
</html>